package com.jiyinit.web.core.business.service;

import java.io.File;
import java.io.IOException;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
import java.util.Random;

import javax.annotation.Resource;

import com.jiyinit.core.framework.base.util.AESUtil;
import com.jiyinit.core.framework.base.util.Check;
import com.jiyinit.web.core.business.entity.TabCoreUserEntity;
import com.jiyinit.web.core.business.enums.CommonEnum;
import com.jiyinit.web.core.business.vo.UserInfoVo;
import com.jiyinit.web.core.common.util.ExcelPrarmUtil;
import com.jiyinit.web.core.common.util.MultipartFileUtil;
import com.jiyinit.web.core.common.util.ReadExcelUtil;
import com.jiyinit.web.core.common.util.UserUtil;
import com.jiyinit.web.core.common.vo.CurrentUserVo;
import org.springframework.stereotype.Service;

import com.jiyinit.core.framework.base.paging.PagingResult;
import com.jiyinit.web.core.business.dao.TabCoreUserSalaryDao;
import com.jiyinit.web.core.business.dto.UserSalaryRequest;
import com.jiyinit.web.core.business.entity.TabCoreUserSalaryEntity;
import org.springframework.web.multipart.MultipartFile;

/**
 * Created By Lichangqin
 * Date : 2019/1/8
 */
@Service("core.userSalaryServiceImpl")
public class UserSalaryServiceImpl {

    @Resource(name = "core.userServiceImpl")
    private UserServiceImpl userService;
	
	@Resource(name = "core.tabCoreUserSalaryDao")
	private TabCoreUserSalaryDao tabCoreUserSalaryDao;
	
	/**
     * 多条件分页查询
     * @param request
     * @return
     */
	public PagingResult<TabCoreUserSalaryEntity> findForPage(UserSalaryRequest request){
        return tabCoreUserSalaryDao.findForPage(request);
    }
	
	/**
	 * id查询
     * @param id
     * @return
     */
	public TabCoreUserSalaryEntity findOne(Integer id){
		return tabCoreUserSalaryDao.findOne(id);
	}
	
	/**
	 * 添加
     * @param entity
     * @return
     */
	public int add(List<TabCoreUserSalaryEntity> list){
		return tabCoreUserSalaryDao.add(list);
	}
    /**
	 * 批量添加
     * @param dataList
     * @return
     */
	public int insertLIst(List<TabCoreUserSalaryEntity> dataList){
		return tabCoreUserSalaryDao.insertList(dataList);
	}
	
	/**
	 * 修改
     * @param entity
     * @return
     */
	public int update(TabCoreUserSalaryEntity entity){
		return tabCoreUserSalaryDao.update(entity);
	}
	
	/**
	 * 删除
     * @param id
     * @return
     */
	public int delete(Integer id){
		return tabCoreUserSalaryDao.delete(id);
	}

    /**
     * 解析校验excel文件内容
     * @author zhaolw
     * @create 2018/11/13 15:04
     * @param
     * @return
     */
   /* public boolean parseWorkers(MultipartFile wordersFile) throws Exception {
        //文件存到服务器临时目录
        File file = MultipartFileUtil.getFileByMultipartFile(wordersFile);
        //读取excel数据内容
        List<List<Object>> list = ReadExcelUtil.readExcel(file);
       *//* //验证模板是否正确
        boolean isExcelTemplateChange = isExcelTemplateChange(list);
        if(!isExcelTemplateChange){
            throw new Exception("导入失败！模板不正确！");
        }*//*
        //判断关键信息是否为空
        boolean a=checkNull(list);
//        int res = getExportData(list);
        boolean b=false;
        try{
            b=MultipartFileUtil.deleteServerFile(file.getAbsolutePath());
        }catch (Exception e){
            e.printStackTrace();
        }
        if (a&&b){
            return true;
        }
        return false;
    }*/

    /**
    * 校验非空
     */
    /*private boolean checkNull(List<List<Object>> list) {

        List<TabCoreUserSalaryEntity> dataList = new ArrayList<>();
        CurrentUserVo userVo = UserUtil.getCurrentUser();
        Date date = new Date();
        //遍历获取excel表格数据
        for (int i = 1; i < list.size(); i++) {
            List<Object> ob = list.get(i);
            if (Check.isNullCollection(ob)) {
                continue;
            }
            TabCoreUserSalaryEntity tabcoreUserSalaryEntity = new TabCoreUserSalaryEntity();
            tabcoreUserSalaryEntity.setCreateId(userVo.getUserId());
            tabcoreUserSalaryEntity.setLastModifyId(userVo.getUserId());
            tabcoreUserSalaryEntity.setCreateTime(date);
            tabcoreUserSalaryEntity.setLastModifyTime(date);
            tabcoreUserSalaryEntity.setIsDelete(CommonEnum.IsDelete.COMMON.getCode());
            try {
                int index = 0;
                //获取excel表里工资基本信息
                String id = (String.valueOf(i));
                String userId = (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));//编号
                String userName = (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));//姓名
                String orgName = (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));//部门
                String userCertificateNo = (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String salaryMonth = (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                //判断非空
                if (Check.isNullStr(userName)||Check.isNullStr(userCertificateNo)||Check.isNullStr(salaryMonth)) {
                    return false;
                }
                //保存工资信息
               return getExportData(list);
            }catch (Exception e){
                e.printStackTrace();
            }
        }
                return  false;
    }


    *//**
     * 获取excel文件内容,入库
     * @author lcq
     * @create 2018/11/13 17:18
     * @param
     * @return
     *//*

    private boolean getExportData(List<List<Object>> list) {

        List<TabCoreUserSalaryEntity> dataList = new ArrayList<>();
        CurrentUserVo userVo = UserUtil.getCurrentUser();
        Date date = new Date();
        //遍历获取excel表格数据
        for (int i = 1; i < list.size(); i++) {

            List<Object> ob = list.get(i);
            if(Check.isNullCollection(ob) ){
                continue;
            }
            TabCoreUserSalaryEntity tabcoreUserSalaryEntity = new TabCoreUserSalaryEntity();
            tabcoreUserSalaryEntity.setCreateId(userVo.getUserId());
            tabcoreUserSalaryEntity.setLastModifyId(userVo.getUserId());
            tabcoreUserSalaryEntity.setCreateTime(date);
            tabcoreUserSalaryEntity.setLastModifyTime(date);
            tabcoreUserSalaryEntity.setIsDelete(CommonEnum.IsDelete.COMMON.getCode());
            try {
                int index = 0;
                //获取excel表里工资基本信息
                String id=(String.valueOf(i));
                String userId=(ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));//编号
                String userName= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));//姓名
                String orgName= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));//部门

                String userCertificateNo= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                TabCoreUserEntity coreUserEntity=userService.getUserInfoByUserCertificateNo(userCertificateNo);
                String salarySecretKey=coreUserEntity.getSalarySecretKey();
                String random=AESUtil.decrypt(salarySecretKey);

                String salaryMonth= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String entryDate= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String positionSalary= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String meritSalary= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String positionAllowance= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String awardSalary= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String agreedSalary= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String computerAllowance= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String mealAllowance= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String recommendAward= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String evectionAllowance= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String reissueSalary= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String overtimeAllowance= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String leaveDeduct= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String sunShine= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String otherAllowance= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String totalSalary= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String companyTotalInsuranceFund= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String companyEndowment= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String companyMedicalInsurance= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String companyUnemployedInsurance= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String companyWoundInsurance= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String companyMaternityInsurance= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String companyAccumulationFund= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String personalTotalInsuranceFund= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String personalEndowment= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String personalMedicalInsurance= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String personalUnemployedInsurance= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String personalAccumulationFund= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String paidAward= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String taxableAmount= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String personalTax= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                String actualPaidSalary= (ExcelPrarmUtil.getStringParam(list.get(i).get(index++)));
                System.out.println(id);
                tabcoreUserSalaryEntity.setUserName(userName);
                tabcoreUserSalaryEntity.setOrgName(orgName);
                tabcoreUserSalaryEntity.setUserId(Integer.parseInt(userId));
                //判断非空后加密
                if (!Check.isNullStr(userCertificateNo)){
                    String userCertificateNo1=AESUtil.encrypt(random,userCertificateNo);
                    tabcoreUserSalaryEntity.setUserCertificateNo(userCertificateNo1);
                }
                if (!Check.isNullStr(salaryMonth)){
                    String salaryMonth1=AESUtil.encrypt(random,salaryMonth);
                    tabcoreUserSalaryEntity.setSalaryMonth(salaryMonth1);
                }
                if (!Check.isNullStr(entryDate)){
                    String entryDate1=AESUtil.encrypt(random,entryDate);
                    tabcoreUserSalaryEntity.setEntryDate(entryDate1);
                }else{
                    String entryDate1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setEntryDate(entryDate1);
                }
                if (!Check.isNullStr(positionSalary)){
                    String positionSalary1=AESUtil.encrypt(random,positionSalary);
                    tabcoreUserSalaryEntity.setPositionSalary(positionSalary1);
                }else{
                    String positionSalary1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setPositionSalary(positionSalary1);
                }
                if (!Check.isNullStr(meritSalary)){
                    String meritSalary1=AESUtil.encrypt(random,meritSalary);
                    tabcoreUserSalaryEntity.setMeritSalary(meritSalary1);
                }else{
                    String meritSalary1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setMeritSalary(meritSalary1);
                }

                if (!Check.isNullStr(positionAllowance)){
                    String positionAllowance1=AESUtil.encrypt(random,positionAllowance);
                    tabcoreUserSalaryEntity.setPositionAllowance(positionAllowance1);
                }else{
                    String positionAllowance1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setPositionAllowance(positionAllowance1);
                }
                if (!Check.isNullStr(awardSalary)){
                    String awardSalary1=AESUtil.encrypt(random,awardSalary);
                    tabcoreUserSalaryEntity.setAwardSalary(awardSalary1);
                }else{
                    String awardSalary1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setAwardSalary(awardSalary1);
                }
                if (!Check.isNullStr(agreedSalary)){
                    String agreedSalary1=AESUtil.encrypt(random,agreedSalary);
                    tabcoreUserSalaryEntity.setAgreedSalary(agreedSalary1);
                }else{
                    String agreedSalary1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setAgreedSalary(agreedSalary1);
                }
                if (!Check.isNullStr(computerAllowance)){
                    String computerAllowance1=AESUtil.encrypt(random,computerAllowance);
                    tabcoreUserSalaryEntity.setComputerAllowance(computerAllowance1);
                }else{
                    String computerAllowance1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setComputerAllowance(computerAllowance1);
                }
                if (!Check.isNullStr(mealAllowance)){
                    String mealAllowance1=AESUtil.encrypt(random,mealAllowance);
                    tabcoreUserSalaryEntity.setMealAllowance(mealAllowance1);
                }else{
                    String mealAllowance1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setMealAllowance(mealAllowance1);
                }
                if (!Check.isNullStr(recommendAward)){
                    String recommendAward1=AESUtil.encrypt(random,recommendAward);
                    tabcoreUserSalaryEntity.setRecommendAward(recommendAward1);
                }else{
                    String recommendAward1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setRecommendAward(recommendAward1);
                }
                if (!Check.isNullStr(evectionAllowance)){
                    String evectionAllowance1=AESUtil.encrypt(random,evectionAllowance);
                    tabcoreUserSalaryEntity.setEvectionAllowance(evectionAllowance1);
                }else{
                    String evectionAllowance1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setEvectionAllowance(evectionAllowance1);
                }
                if (!Check.isNullStr(reissueSalary)){
                    String reissueSalary1=AESUtil.encrypt(random,reissueSalary);
                    tabcoreUserSalaryEntity.setReissueSalary(reissueSalary1);
                }else{
                    String reissueSalary1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setReissueSalary(reissueSalary1);
                }
                if (!Check.isNullStr(overtimeAllowance)){
                    String overtimeAllowance1=AESUtil.encrypt(random,overtimeAllowance);
                    tabcoreUserSalaryEntity.setOvertimeAllowance(overtimeAllowance1);
                }else{
                    String overtimeAllowance1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setOvertimeAllowance(overtimeAllowance1);
                }
                if (!Check.isNullStr(leaveDeduct)){
                    String leaveDeduct1=AESUtil.encrypt(random,leaveDeduct);
                    tabcoreUserSalaryEntity.setLeaveDeduct(leaveDeduct1);
                }else{
                    String leaveDeduct1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setLeaveDeduct(leaveDeduct1);
                }
                if (!Check.isNullStr(sunShine)){
                    String sunShine1=AESUtil.encrypt(random,sunShine);
                    tabcoreUserSalaryEntity.setSunShine(sunShine1);
                }else{
                    String sunShine1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setSunShine(sunShine1);
                }
                if (!Check.isNullStr(otherAllowance)){
                    String otherAllowance1=AESUtil.encrypt(random,otherAllowance);
                    tabcoreUserSalaryEntity.setOtherAllowance(otherAllowance1);
                }else{
                    String otherAllowance1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setOtherAllowance(otherAllowance1);
                }
                if (!Check.isNullStr(totalSalary)){
                    String totalSalary1=AESUtil.encrypt(random,totalSalary);
                    tabcoreUserSalaryEntity.setTotalSalary(totalSalary1);
                }else{
                    String totalSalary1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setTotalSalary(totalSalary1);
                }
                if (!Check.isNullStr(companyTotalInsuranceFund)){
                    String companyTotalInsuranceFund1=AESUtil.encrypt(random,companyTotalInsuranceFund);
                    tabcoreUserSalaryEntity.setCompanyTotalInsuranceFund(companyTotalInsuranceFund1);
                }else{
                    String companyTotalInsuranceFund1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setCompanyTotalInsuranceFund(companyTotalInsuranceFund1);
                }
                if (!Check.isNullStr(companyEndowment)){
                    String companyEndowment1=AESUtil.encrypt(random,companyEndowment);
                    tabcoreUserSalaryEntity.setCompanyEndowment(companyEndowment1);
                }else{
                    String companyEndowment1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setCompanyEndowment(companyEndowment1);
                }
                if (!Check.isNullStr(companyMedicalInsurance)){
                    String companyMedicalInsurance1=AESUtil.encrypt(random,companyMedicalInsurance);
                    tabcoreUserSalaryEntity.setCompanyMedicalInsurance(companyMedicalInsurance1);
                }else{
                    String companyMedicalInsurance1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setCompanyMedicalInsurance(companyMedicalInsurance1);
                }
                if (!Check.isNullStr(companyUnemployedInsurance)){
                    String companyUnemployedInsurance1=AESUtil.encrypt(random,companyUnemployedInsurance);
                    tabcoreUserSalaryEntity.setCompanyUnemployedInsurance(companyUnemployedInsurance1);
                }else{
                    String companyUnemployedInsurance1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setCompanyUnemployedInsurance(companyUnemployedInsurance1);
                }
                if (!Check.isNullStr(companyWoundInsurance)){
                    String companyWoundInsurance1=AESUtil.encrypt(random,companyWoundInsurance);
                    tabcoreUserSalaryEntity.setCompanyWoundInsurance(companyWoundInsurance1);
                }else{
                    String companyWoundInsurance1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setCompanyWoundInsurance(companyWoundInsurance1);
                }
                if (!Check.isNullStr(companyMaternityInsurance)){
                    String companyMaternityInsurance1=AESUtil.encrypt(random,companyMaternityInsurance);
                    tabcoreUserSalaryEntity.setCompanyMaternityInsurance(companyMaternityInsurance1);
                }else{
                    String companyMaternityInsurance1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setCompanyMaternityInsurance(companyMaternityInsurance1);
                }
                if (!Check.isNullStr(companyAccumulationFund)){
                    String companyAccumulationFund1=AESUtil.encrypt(random,companyAccumulationFund);
                    tabcoreUserSalaryEntity.setCompanyAccumulationFund(companyAccumulationFund1);
                }else{
                    String companyAccumulationFund1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setCompanyAccumulationFund(companyAccumulationFund1);
                }
                if (!Check.isNullStr(personalTotalInsuranceFund)){
                    String personalTotalInsuranceFund1=AESUtil.encrypt(random,personalTotalInsuranceFund);
                    tabcoreUserSalaryEntity.setPersonalTotalInsuranceFund(personalTotalInsuranceFund1);
                }else{
                    String personalTotalInsuranceFund1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setPersonalTotalInsuranceFund(personalTotalInsuranceFund1);
                }
                if (!Check.isNullStr(personalEndowment)){
                    String personalEndowment1=AESUtil.encrypt(random,personalEndowment);
                    tabcoreUserSalaryEntity.setPersonalEndowment(personalEndowment1);
                }else{
                    String personalEndowment1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setPersonalEndowment(personalEndowment1);
                }
                if (!Check.isNullStr(personalMedicalInsurance)){
                    String personalMedicalInsurance1=AESUtil.encrypt(random,personalMedicalInsurance);
                    tabcoreUserSalaryEntity.setPersonalMedicalInsurance(personalMedicalInsurance1);
                }else{
                    String personalMedicalInsurance1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setPersonalMedicalInsurance(personalMedicalInsurance1);
                }
                if (!Check.isNullStr(personalUnemployedInsurance)){
                    String personalUnemployedInsurance1=AESUtil.encrypt(random,personalUnemployedInsurance);
                    tabcoreUserSalaryEntity.setPersonalUnemployedInsurance(personalUnemployedInsurance1);
                }else{
                    String personalUnemployedInsurance1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setPersonalUnemployedInsurance(personalUnemployedInsurance1);
                }
                if (!Check.isNullStr(personalAccumulationFund)){
                    String personalAccumulationFund1=AESUtil.encrypt(random,personalAccumulationFund);
                    tabcoreUserSalaryEntity.setPersonalAccumulationFund(personalAccumulationFund1);
                }else{
                    String personalAccumulationFund1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setPersonalAccumulationFund(personalAccumulationFund1);
                }
                if (!Check.isNullStr(paidAward)){
                    String paidAward1=AESUtil.encrypt(random,paidAward);
                    tabcoreUserSalaryEntity.setPaidAward(paidAward1);
                }else{
                    String paidAward1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setPaidAward(paidAward1);
                }
                if (!Check.isNullStr(taxableAmount)){
                    String taxableAmount1=AESUtil.encrypt(random,taxableAmount);
                    tabcoreUserSalaryEntity.setTaxableAmount(taxableAmount1);
                }else{
                    String taxableAmount1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setTaxableAmount(taxableAmount1);
                }
                if (!Check.isNullStr(personalTax)){
                    String personalTax1=AESUtil.encrypt(random,personalTax);
                    tabcoreUserSalaryEntity.setPersonalTax(personalTax1);
                }else{
                    String personalTax1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setPersonalTax(personalTax1);
                }
                if (!Check.isNullStr(actualPaidSalary)){
                    String actualPaidSalary1=AESUtil.encrypt(random,actualPaidSalary);
                    tabcoreUserSalaryEntity.setActualPaidSalary(actualPaidSalary1);
                }else{
                    String actualPaidSalary1=AESUtil.encrypt(random,"-");
                    tabcoreUserSalaryEntity.setActualPaidSalary(actualPaidSalary1);
                }

               *//* //非空校验
                verifyExportData(tabExportDataEntity, dataList);*//*
            } catch (Exception e){
                *//*tabExportDataEntity.setErrorType(0);
                tabExportDataEntity.setErrorMessage(ExportDataErrorMessage.UNKNOW_ERROR);*//*
                e.printStackTrace();
            } finally {
                int j = i-1;
                dataList.add(j,tabcoreUserSalaryEntity);

            }
        }
       int i= insertLIst(dataList);
        if(i>0){
            return true;
        }
        return false;
    }*/

}
